﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Pagebase/PageDialog.Master" AutoEventWireup="true" CodeBehind="Dialog_SelectStaff.aspx.cs" Inherits="webnew.Systems.Dialog_SelectStaff" %>
<%@ Register assembly="AspNetPager" namespace="Wuqi.Webdiyer" tagprefix="webdiyer" %>
<%@ Register src="../UserControls/UcCompany.ascx" tagname="UcCompany" tagprefix="uc1" %>
<asp:Content ID="Content1" ContentPlaceHolderID="ContentPlaceHolder1" runat="server">
<script type="text/javascript">
        

 function document.onkeydown() {
        var e = event.srcElement;
        if (event.keyCode == 13) {
            document.getElementById("<%=btnSearch.ClientID%>").click();
            return false;
        }
    }

     
        ////////////////////////////////////////////////////////////////////////////////
       

        function getStaffInfo(staffId, staffName) {
            self.parent.tb_remove();
            self.parent.getSelStaffInfo(staffId, staffName);
        }
    </script>
  
    <table style=" width:650px;">
        
        <tr>
            <td>
                <div id='t' style="overflow:auto;" align="left">
<div id="searchbox">  <div >
        所属单位：<uc1:uccompany ID="UcCompany1" runat="server" />
        所属部门：<asp:DropDownList ID="ddlOADept" runat="server">
        </asp:DropDownList>
    
        状态：<asp:DropDownList ID="dllStatus" runat="server">
            <asp:ListItem Value="全部">全部</asp:ListItem>
            <asp:ListItem Value="0">启用</asp:ListItem>
            <asp:ListItem Value="2">停用</asp:ListItem>
        </asp:DropDownList>
    
        员工姓名：<asp:TextBox ID="txtTrueName" runat="server" CssClass="txt" Width="94px"></asp:TextBox>
             <asp:Button 
            ID="btnSearch" runat="server" CssClass="btn" onclick="btnSearch_Click" 
            Text="检索" />                    
    
      </div>
      
        <div>
        
             职位关键字：<asp:TextBox 
                       ID="txtTitleName" runat="server" CssClass="txt" 
            MaxLength="10" Width="98px"></asp:TextBox>
    
    </div>

 <asp:UpdatePanel ID="upanlGrdView" runat="server" UpdateMode="Conditional" >
<ContentTemplate>
     <div id="contentbox">

        <asp:GridView ID="grdView" runat="server" AutoGenerateColumns="False" 
            CssClass="dgv"  Width ="98%" DataKeyNames="id" onrowdatabound="grdView_RowDataBound" 
            PageSize="10">
            <Columns>
                <asp:TemplateField>
                   
                    <ItemTemplate>
                        <asp:CheckBox ID="chkitem" onclick="chkclick(this);" runat="server" />
                    </ItemTemplate>
                    
                </asp:TemplateField>
              
                <asp:BoundField DataField="TrueName" HeaderText="员工姓名"  />
                <asp:BoundField DataField="Sex" HeaderText="性别" />
                <asp:BoundField DataField="OACompName" HeaderText="所属单位" />
                <asp:BoundField DataField="OADeptName" HeaderText="所属部门" />            
                <asp:BoundField DataField="titleName" HeaderText="职务" />
                         
            </Columns>
             <HeaderStyle CssClass="x-panel-header" />    
             <AlternatingRowStyle CssClass="dgvitem1" />         
             <RowStyle CssClass="dgvitem" />
        </asp:GridView>
        </div>
        <div id="footbox">
            <webdiyer:AspNetPager ID="AspNetPager1" runat="server" CssClass="paginator" 
                CurrentPageButtonClass="cpb" FirstPageText="首页" LastPageText="尾页" 
                NextPageText="后页" PageSize="10" PrevPageText="前页" ShowBoxThreshold="2" 
                onpagechanged="AspNetPager1_PageChanged">
            </webdiyer:AspNetPager>
        </div>
        
</ContentTemplate>
         <Triggers>           
             <asp:AsyncPostBackTrigger ControlID="btnSearch" EventName="Click" />                        
         </Triggers>

    </asp:UpdatePanel>
    </div>
    <asp:UpdateProgress ID="uproLoad" runat="server" 
        AssociatedUpdatePanelID="upanlGrdView" >

            <ProgressTemplate >

               <div id="loadPic"></div>                   
                 <div  id="loadFont" >数据正在查询,请耐心等待...</div>     
            </ProgressTemplate>

        </asp:UpdateProgress>
    
                </div>
               
            </td>
        </tr>
    </table>
</asp:Content>
